package com.googlecode.excavator.test.provider;

import junit.framework.Assert;

import org.junit.Before;
import org.junit.BeforeClass;
import org.junit.Test;

import com.googlecode.excavator.provider.ProviderProxyFactory;
import com.googlecode.excavator.test.service.SayService;
import com.googlecode.excavator.test.service.impl.SayServiceImpl;

public class ProviderTestCase {

	private static ProviderProxyFactory factory;
	private SayService sayService;
	
	@BeforeClass
	public static void beforeClass() throws Exception {
		try {
			factory = ProviderProxyFactory.singleton();
		}catch(Exception e) {
			e.printStackTrace();
			throw e;
		}
		
	}
	
	@Before
	public void before() throws Exception {
		sayService = factory.proxy(SayService.class, new SayServiceImpl(), "DEFAULT", "1.0.0", 100, null);
	}
	
	@Test
	public void test_000() {
		Assert.assertTrue(true);
	}
	
//	@Test
	public void test_001() throws Exception {
		Assert.assertNotNull(sayService);
		System.in.read();
		
	}
	
}
